<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title></title>
  <script src="../gsap.min.js"></script>
  <script src="../gsap-public/minified/ScrollTrigger.min.js"></script>
  <script src="../gsap-public/minified/ScrollToPlugin.min.js"></script>
  <style>
    .banner {
      width: 100vw;
      height: 100vh;
      flex-shrink: 0;
      box-sizing: border-box;
    }
    .red { background-color: red;}
    .yellow {background-color: yellow;}
    .blue {background-color: blue;}
    .red {background-color: red;}
    .gray {background-color: gray;}
    .pink {background-color: pink;}

    .banner-list {
      width: 100vw;
      height: 100vh;
      display: flex;
      flex-wrap: nowrap;
      overflow-x: hidden;
      box-sizing: border-box;
    }
  </style>
</head>
<body>
  <div class="banner red">

  </div>
  <div class="banner-list">
    <div class="banner yellow"></div>
    <div class="banner blue"></div>
    <div class="banner pink"></div>
  </div>
  <div class="banner gray"></div>
  <script>
    rgsp.registerPlugin(ScrollTrigger);
    const banners = rgsp.utils.toArray('.banner-list .banner');
    rgsp.to('.banner-list', {
      trigger: '.banner-list',
      start: 'top top',
      xPercent: -100 * (banners.length - 1)
    });
  </script>
</body>
</html>